﻿<%@ Control Language="C#" AutoEventWireup="true" CodeFile="ManagerRoleDepart.ascx.cs"
    Inherits="Member_Control_ManagerRoleDepart" %>
<h2>
    Phân quyền phòng ban :
    <asp:Label ID="lblDepartName" runat="server"></asp:Label>
</h2>
<div id="tab">
    <ul>
        <li><a href="#role"><span>Quyền</span></a></li>
        <li><a href="#module"><span>Nhóm chức năng</span></a></li>
    </ul>
    <div id="role">
        <div style="margin-bottom: 20px">
            <table class="grid">
                <tr>
                    <th width="30px">
                    </th>
                    <th>
                        Quyền
                    </th>
                    <th width="40px">
                    </th>
                </tr>
                <asp:Repeater ID="repRole" runat="server">
                    <ItemTemplate>
                        <tr>
                            <td align="center">
                                <%# Container.ItemIndex + 1 %>
                            </td>
                            <td>
                                <%# Eval("RoleName") %>
                            </td>
                            <td align="center">
                                <asp:CheckBox ID="chkRole" runat="server" Checked='<%# Convert.ToBoolean(Eval("IsRole")) %>' />
                                <asp:HiddenField ID="hid" runat="server" Value='<%# Eval("RoleId") %>' />
                            </td>
                        </tr>
                    </ItemTemplate>
                </asp:Repeater>
            </table>
        </div>
        <span class="button">
            <asp:Button ID="btnRole" runat="server" Text="Cập nhật" OnClick="btnRole_Click" />
            <span></span></span>
    </div>
    <div id="module">
        <div style="margin-bottom: 20px">
            <table class="grid">
                <tr>
                    <th width="30px">
                    </th>
                    <th>
                        Nhóm chức năng
                    </th>
                    <th width="40px">
                    </th>
                </tr>
                <asp:Repeater ID="repModule" runat="server">
                    <ItemTemplate>
                        <tr>
                            <td align="center">
                                <%# Container.ItemIndex + 1 %>
                            </td>
                            <td>
                                <%# Eval("ModName") %>
                            </td>
                            <td align="center">
                                <asp:CheckBox ID="chkModule" runat="server" Checked='<%# Convert.ToBoolean(Eval("IsRole")) %>' />
                                <asp:HiddenField ID="hid" runat="server" Value='<%# Eval("ModCode") %>' />
                            </td>
                        </tr>
                    </ItemTemplate>
                </asp:Repeater>
            </table>
        </div>
        <span class="button">
            <asp:Button ID="btnModule" runat="server" Text="Cập nhật" OnClick="btnModule_Click" />
            <span></span></span>
    </div>
</div>

<script type="text/javascript">
    $(document).ready(function(){
        $("#tab").tabs();
    });
</script>

